package com.kube.design.responsibility;

/**
 * @author q.zhangr
 * @version 1.0.0
 * @date 2020/7/15
 */
public class ResponsibilityTest {


    public static void main(String[] args) {


        AbstractHandler teacherHandler = new TeacherHandler();

        AbstractHandler departmentHandler = new DepartmentHandler();

        AbstractHandler leaderHandler = new LeaderHandler();

        teacherHandler.setAbstractHandler(departmentHandler);

        departmentHandler.setAbstractHandler(leaderHandler);

        teacherHandler.handlerRequest("张三", 50);
    }


}
